<?php $page = "Home"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>N02233598</title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <link rel="stylesheet" type="text/css" href="style.css" />
  </head>

  <body>
    <?php
        include("inc/nav.php");
        include("inc/header.php");
    ?>
    <h1>Users</h1>
        <a href="edit.php">Add</a>
        <table>
                <tr>
                <th>FirstName</th>
                <th>LastName</th>
                <th>PictureURL</th>
                <th>FBID</th>
                <th>Lookup_id</th>
            </tr>
                        <? while($rs = $result->fetch_assoc()){ ?>
                <tr class="<?= $_REQUEST['new_id']==$rs['id'] ? 'new-row' : '' ?>">
                        <td>
                                                <?=$rs['FirstName']?>
                    </td>
                    <td>
                        <?=$rs['LastName']?>
                     </td>
                        <td><?=$rs['PictureURL']?></td>
                    <td><?=$rs['FBID']?></td>
                    <td><?=$rs['Lookup_id']?></td>
                    <td>
                        <a href="edit.php?id=<?=$rs['id']?>">Edit</a>
                        <a href="delete.php?id=<?=$rs['id']?>">Delete</a>
                        <a href="details.php?id=<?=$rs['id']?>">View</a>
                        <a href="../ContactMethods/?User_id=<?=$rs['id']?>">Contact Methods</a>
                    </td>
                </tr>
            <? } ?>
        </table>
    <?php include("inc/footer.php"); ?>
  </body>
</html>
